#include <iostream>
#include <cmath>
#include <cstring>
#include <algorithm>
using namespace std;

typedef long double ld;
const ld eps = 1e-10;
const int N = 1000005;
ld a[N];
int n;

bool check(ld r){
    ld x = r+1,y = r+1;
    for(int k=1;k<=n;k++){
        if(r*r<a[k]||sqrtl(r*r-a[k])<0.5)
            return false;
        if(x<y)
            swap(x,y);
        x = min(x-1,sqrtl(r*r-a[k]));
    }
    return x+y>=2;
}

int main(){
    freopen("temple.in","r",stdin);
    freopen("temple.out","w",stdout);
    scanf("%d",&n);
    for(int k=1;k<=n;k++){
        ld x,y;
        scanf("%Lf%Lf",&x,&y);
        if(x<y)
            swap(x,y);
        a[k] = x*x/4+y*y;
    }
    sort(a+1,a+1+n);
    ld l = 0,r = 1e9;
    while(l+eps<r){
        ld mid = (l+r)/2;
        if(check(mid))
            r = mid;
        else
            l = mid;
    }
    printf("%.8LF",l);
    return 0;
}